!!! 5
%html
  %head
    %meta(name="viewport" content="width=device-width, minimum-scale=1, maximum-scale=1")
    = stylesheet_link_tag "application"
  %body
    = render :partial => "gmindapp/menu"
    %div{"data-id" => "main", "data-role" => "panel", "data-backbtn"=>"false"}
      - if @cache
        - cache = {}
      - else
        - cache = {"data-cache"=>"never"}
      - if @backbtn
        - backbtn= {"data-backbtn"=>"true"}
      - else
        - backbtn= {"data-backbtn"=>"false"}
      %div{{"data-role" => "page"}.merge(cache) }
        %div{{"data-role" => "header"}.merge(backbtn)}
          %h1= @title || DEFAULT_TITLE
        %div{"data-role" => "content"}
          = yield

      = render :partial => "gmindapp/about"
      = render :partial => "gmindapp/static"
    = javascript_include_tag "application"

:javascript
  $('div').live('pagehide', function(e,ui) {
    var page = $(e.target);
    if(page.attr('data-cache') == 'never') {
      page.remove();
    };
  });

= handle_gma_notice
